package monitora.bean;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.NamedNativeQueries;
import javax.persistence.NamedNativeQuery;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;

@Entity
@Table(name="TB_PREFEITURA", schema="MONITORA")

@NamedNativeQueries({
	@NamedNativeQuery(name="prefeituras", query="SELECT * FROM MONITORA.TB_PREFEITURA ORDER BY NOME", resultClass=PrefeituraBean.class)
})
public class PrefeituraBean implements Serializable {

	@Id
	@SequenceGenerator(name="PREFEITURA", sequenceName="MONITORA.SQ_PREFEITURA")
	@GeneratedValue(generator="PREFEITURA", strategy=GenerationType.AUTO)
	@Column(name="CD_PREFEITURA")
	private int codigo;
	
	@Column(name="NOME")
	private String nome;
	
	@Column(name="CPF")
	private String cpf;
	
	@Column(name="SENHA")
	private String senha;

	public int getCodigo() {
		return codigo;
	}

	public void setCodigo(int codigo) {
		this.codigo = codigo;
	}

	public String getNome() {
		return nome;
	}

	public void setNome(String nome) {
		this.nome = nome;
	}

	public String getCpf() {
		return cpf;
	}

	public void setCpf(String cpf) {
		this.cpf = cpf;
	}

	public String getSenha() {
		return senha;
	}

	public void setSenha(String senha) {
		this.senha = senha;
	}
}
